package com.bing.bingPro.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDate;
import java.util.Date;
import java.util.Objects;

import lombok.Data;

/**
 * 
 * @TableName t_network_topology_pon_area_day
 */
@TableName(value ="t_network_topology_pon_area_day")
@Data
public class TNetworkTopologyPonAreaDay implements Serializable {



    @TableField(value = "data_month")
    private String dataMonth;
    /**
     * 数据日期
     */
    @TableField(value = "data_time")
    private Date dataTime;

    /**
     * 省份简写
     */
    @TableField(value = "province")
    private String province;

    /**
     * OLT IP
     */
    @TableField(value = "olt_ip")
    private String oltIp;


    /**
     * PON口
     */
    @TableField(value = "olt_pon")
    private String oltPon;

    /**
     * 省份
     */
    @TableField(value = "province_name")
    private String provinceName;

    /**
     * 地市
     */
    @TableField(value = "city_name")
    private String cityName;

    /**
     * 区县
     */
    @TableField(value = "region_name")
    private String regionName;

    /**
     * 用户数
     */
    @TableField(value = "user_num")
    private Integer userNum;

    /**
     * 更新时间
     */
    @TableField(value = "update_time")
    private Date updateTime;

    @TableField(value = "data_count")
    private Integer dataCount;
    @TableField(exist = false)
    private String pk;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;


    @Override
    public int hashCode() {
        // 根据oltPon、oltIp和cityName计算hashCode，确保它们相同的对象具有相同的hashCode
        return Objects.hash(oltPon, oltIp, cityName);
    }

    @Override
    public boolean equals(Object obj) {
        if (this == obj) return true;
        if (obj == null || getClass() != obj.getClass()) return false;
        TNetworkTopologyPonAreaDay other = (TNetworkTopologyPonAreaDay) obj;
        // 根据oltPon、oltIp和cityName比较对象是否相等
        return Objects.equals(oltPon, other.oltPon) &&
                Objects.equals(oltIp, other.oltIp) &&
                Objects.equals(cityName, other.cityName);
    }
}